import { http } from "@/utils/http.js";

//提现列表
export const mySettle = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/list",
    params: data,
  });
};

//结算费率
export const settleRate = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/options",
    params: data,
  });
};

export const myBankcard = (data) => {
  return http.request({
    method: "get",
    url: "/bank/myCard",
    params: data,
  });
};

export const customermyBalance = (data) => {
  return http.request({
    method: "get",
    url: "/member/customer/myBalance",
    params: data,
  });
};

// 申请转出 -
export const applyBrokerage = (data) => {
  return http.request({
    method: "POST",
    url: "/user/balance/settleApply",
    data,
  });
};

//添加银行卡
export const bankAdd = (data) => {
  return http.request({
    method: "POST",
    url: "/bank/cardCreate",
    data,
  });
};

export const settleDetail = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/detail",
    params: data,
  });
};

export const selectbankList = (data) => {
  return http.request({
    method: "get",
    url: "/bank/list",
    params: data,
  });
};

//计算机服务费
export const computeBrokerage = (data) => {
  return http.request({
    method: "POST",
    url: "/user/balance/settleCheck",
    data,
  });
};

// 转赠金额
export const sendGift = (data) => {
  return http.request({
    method: "POST",
    url: "/member/customer/sendGift",
    data,
  });
};

export const giftSendList = (data) => {
  return http.request({
    method: "get",
    url: "/member/customer/giftSendList",
    params: data,
  });
};

//转赠二维码
export const getGiftQrcode = (data) => {
  return http.request({
    method: "POST",
    url: "/member/share/getGiftQrcode",
    data,
  });
};

export const giftDetail = (data) => {
  return http.request({
    method: "get",
    url: "/member/customer/giftDetail",
    params: data,
  });
};

export const drawGift = (data) => {
  return http.request({
    method: "POST",
    url: "/member/customer/drawGift",
    data,
  });
};

export const settletype = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/type",
    params: data,
  });
};

export const settletotal = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/total",
    params: data,
  });
};

export const expectedlist = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/expected_list",
    params: data,
  });
};

export const purchaselist = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/purchase_list",
    params: data,
  });
};

export const expecteddetail = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/expected_detail",
    params: data,
  });
};

export const purchasedetail = (data) => {
  return http.request({
    method: "get",
    url: "/user/balance/purchase_detail",
    params: data,
  });
};

//认证
export const userauth = (data) => {
  return http.request({
    method: "POST",
    url: "/user/auth",
    data,
  });
};

//签约地址
export const thirdPartySignApi = (data) => {
  return http.request({
    method: "get",
    url: "/user/thirdPartySign",
    params: data,
  });
};

//签约认证信息
export const getAuthApi = (data) => {
  return http.request({
    method: "get",
    url: "/user/getAuth",
    params: data,
  });
};

//认证
export const balanceSelect = (data) => {
  return http.request({
    method: "POST",
    url: "/user/balance/select",
    data,
  });
};
